package com.example.common.tools.rxbug

class TagMessage {

    var mEvent: Any
    var mTag: String


    constructor(event: Any, tag: String){
        mEvent = event
        mTag = tag
    }

    fun isSameType(eventType: Class<*>, tag: String): Boolean {
        return Utils.equals(getEventType(), eventType) && Utils.equals(this.mTag, tag)
    }

    fun getEventType(): Class<*> {
        return Utils.getClassFromObject(mEvent)!!
    }

    override fun toString(): String {
        return "event: $mEvent, tag: $mTag"
    }
}

